﻿namespace ysh
{
	using Autodesk.Revit.UI;

	using ui;

	using res;

	using core;

	/// <summary>
	/// Setup whole plugins interface with tabs,panels,button...
	/// </summary>
	public class SetupInterface
	{
		#region constructor

		/// <summary>
		/// Default constructor.
		/// </summary>
		public SetupInterface()
		{

		}
		#endregion

		#region public methods

		/// <summary>
		/// Initialize all interface elements on custom created Revit tab.
		/// </summary>
		/// <param name="app"></param>
		public void Initialize(UIControlledApplication app)
		{
			//Create ribbon tab.
			string tabName = "Ysh's Bim Blog";
			app.CreateRibbonTab(tabName);

			//Create the annotate commands panel.
			var anntationCommandsPanel =  app.CreateRibbonPanel(tabName, "Annotation Commands");

			//Populate button data model.
			var TagWallButtonData = new RevitPushButtonDataModel
			{
				Label = "Tag Wall\nLayers",
				Panel = anntationCommandsPanel,
				Tooltip = "This is some simple tooltip text,\nreplace it with real one later,...",
				CommandNameSpacePath = TagWallLayersCommand.GetPath(),
				IconImageName = "icon_img_32x32.png",
				TooltipImageName = "tooltip_image_320x320.png"
			};

			//Create button from provided data
			var TagWallButton = RevitPushButton.Create(TagWallButtonData);
		}

		#endregion
	}
}
